var http = require('http');
var url=require('url');
var str="http://m.maizuo.com/v4/api/billboard/home?__t=1494913271816"
//console.log(url.parse(str));
var options = {
    hostname: 'm.maizuo.com',
    port: 80,
    path: '/v4/api/billboard/home?__t=1494913271816',
    method: 'get'
}
var request=http.request(options,function(res){
	var resData='';
	res.on('data',function(chunk){
		resData += chunk;
	});
	res.on('end',function(){
		//console.log(resData);
		var subjects = JSON.parse(resData);
		res.send(subjects);
		console.log(subjects);
	})
})

request.on('error', function(err) {
    console.log(err);
})

request.end();